/**
 * elancom Corporation copy right 2012 - 2015  
 *   
 * $Header$
 * $Id$
 * $Author$
 * $Date$
 * $Revision$
 */
package com.elancom.framework.web;

import java.util.Enumeration;
import java.util.Map;

import com.elancom.framework.web.context.RequestContext;

/**
 * @author elancom
 * @date 2012-7-16
 */
public class RequestContextDelegate implements RequestDelegate {
	/**
	 * 
	 */
	public RequestContextDelegate() {
		super();
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.elancom.framework.web.RequestDelegate#getAttribute(java.lang.String)
	 */
	@Override
	public Object getAttribute(String arg0) {
		return RequestContext.getContext().getAttribute(arg0);
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.elancom.framework.web.RequestDelegate#getAttributeNames()
	 */
	@Override
	public Enumeration<String> getAttributeNames() {
		return RequestContext.getContext().getAttributeNames();
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.elancom.framework.web.RequestDelegate#getParameter(java.lang.String)
	 */
	@Override
	public String getParameter(String arg0) {
		return RequestContext.getContext().getParameter(arg0);
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.elancom.framework.web.RequestDelegate#getParameterMap()
	 */
	@Override
	public Map<String, Object> getParameterMap() {
		return RequestContext.getContext().getParameterMap();
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.elancom.framework.web.RequestDelegate#getParameterNames()
	 */
	@Override
	public Enumeration<String> getParameterNames() {
		return RequestContext.getContext().getParameterNames();
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.elancom.framework.web.RequestDelegate#getParameterValues(java.lang.String)
	 */
	@Override
	public String[] getParameterValues(String arg0) {
		return RequestContext.getContext().getParameterValues(arg0);
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.elancom.framework.web.RequestDelegate#removeAttribute(java.lang.String)
	 */
	@Override
	public void removeAttribute(String arg0) {
		RequestContext.getContext().removeAttribute(arg0);
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.elancom.framework.web.RequestDelegate#setAttribute(java.lang.String, java.lang.Object)
	 */
	@Override
	public void setAttribute(String arg0, Object arg1) {
		RequestContext.getContext().setAttribute(arg0, arg1);
	}
}
